class MenuUtil {
    constructor() {
    }

    static activeMenu(url, index) {
        let strings = url.split('/');
        if (index) {
            let s = strings.slice(0, index + 1).toString();
            let replace = s.replace(/,/g, "/");
            return replace;
        }
        return url;
    }
}

export default MenuUtil;